commit: Clarify reasoning for "commit-update-summary" default
authorMatthew Barnes <mbarnes@redhat.com>
Fri, 11 Sep 2015 17:15:58 +0000 (13:15 -0400)
committerMatthew Barnes <mbarnes@redhat.com>
Fri, 11 Sep 2015 17:19:01 +0000 (13:19 -0400)
In case anyone else gets the idea of changing the default for archive-z2
repos.  Should have the rationale captured in the source code somewhere.

src/ostree/ot-builtin-commit.c

index db3700b2a894aa6ef507dace4546d4677ae3895b..3176ae93ea6cde7ae57611b483211abeea570567 100644 (file)
@@ -524,6 +524,11 @@ ostree_builtin_commit (int argc, char **argv, GCancellable *cancellable, GError
       if (!ostree_repo_commit_transaction (repo, &stats, cancellable, error))
         goto out;
 
+      /* The default for this option is FALSE, even for archive-z2 repos,
+       * because ostree supports multiple processes committing to the same
+       * repo (but different refs) concurrently, and in fact gnome-continuous
+       * actually does this.  In that context it's best to update the summary
+       * explicitly instead of automatically here. */
       if (!ot_keyfile_get_boolean_with_default (ostree_repo_get_config (repo), "core",
                                                 "commit-update-summary", FALSE,
                                                 &update_summary, error))